package com.douqu.game.auth.database.mapper;


import com.douqu.game.auth.database.model.NoticeMessageModel;
import com.douqu.game.auth.database.model.ServerModel;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface ServerMapper {
    int insert(ServerModel record);

    ServerModel selectByPrimaryKey(@Param("id")Integer id);

    ServerModel selectByKeyAndRule(@Param("id") Integer id,
                                   @Param("ruleId")Integer ruleId);

    ServerModel getNewServer(@Param("ruleId")Integer ruleId);

    List<ServerModel> getList(@Param("ruleId")Integer ruleId);

    List<ServerModel> getListWhite(@Param("ruleId")Integer ruleId);

    List<ServerModel> findList(@Param("areaId") Integer areaId, @Param("gmVersion") String gmVersion);

    void changeStatus(@Param("id") Integer id, @Param("status")Integer status);

    NoticeMessageModel getNotice(@Param("platform") int platform);

    String getCampActivityHttpHost(@Param("serverId") Integer serverId);

    void updateVersion(@Param("id") Integer id,
                       @Param("version") String version);

    List<Map<String, Object>> getCampActivityServerList();

    String getCampActivityHttpHostByServerId(@Param("serverId") Integer serverId);

    String getCampActivityHttpHostById(@Param("id") Integer id);

    List<Integer> getAll();

}